100 CLS:PRINT:PRINT"Display routine for frequencies and intensities.":PRINT
110 PRINT:PRINT"This is in a menu format; to get menu, press 'M' in command mode.":PRINT:BEEP:PRINT"NOTE: IT IS NECESSARY TO READ IN THE LINES VIA THE 'R' COMMAND IF AUTO-READ":PRINT" NOT IN EFFECT!": GOSUB 63999
120 IF IREAD=1 THEN BF = 0: GOSUB 5100
200 CLS:PRINT:PRINT"Command ('M' for menu): ";:GOSUB 500
210 IF P$ = "E" THEN GOSUB 1000
215 IF P$ = "W" THEN GOSUB 900: CHAIN "nmr6"
220 IF P$ = "L" THEN GOSUB 3000
225 IF P$ = "T" THEN GOSUB 19000
230 IF P$ = "M" THEN GOSUB 2000
240 IF P$ = "D" THEN GOSUB 4000
250 IF P$ = "R" THEN GOSUB 5000
260 IF P$ = "S" THEN GOSUB 20000
270 IF P$ <> "Q" THEN 280
275 CLS: PRINT: PRINT"Returning control to system.": PRINT: END
280 IF P$ = "U" THEN GOSUB 6000
290 IF P$ = "C" THEN GOSUB 10000
300 IF P$ = "P" THEN GOSUB 900: CHAIN "nmr5"
310 IF P$ = "V" THEN GOSUB 14000
320 IF P$ = "F" THEN GOSUB 16000
330 IF P$ = "Z" THEN LPRINT CHR$(12);
340 IF P$ = "A" THEN GOSUB 18000
390 GOTO 200
500 P$ = INKEY$: IF P$ = "" THEN 500
510 IF ASC(P$) > 90 THEN P$ = CHR$(ASC(P$) - 32)
520 PRINT P$
530 RETURN
800 PRINT:PRINT"Do you desire printed output? ";
810 A$ = INKEY$: IF A$ = "" THEN 810
820 IF ASC(A$) > 90 THEN A$ = CHR$(ASC(A$) - 32)
830 PRINT A$
840 IF A$ = "Y" THEN IPRINT = 1 ELSE IF A$ = "N" THEN IPRINT = 0 ELSE BEEP: GOTO 800
10160 SL = SLINES(I,0): SM = 1000*(SL - INT(SL)): SL = INT(SL): SM = INT(SM+.1)
10170 PRINT SL;">";SM
10180 PRINT "Frequency =";SLINES(I,1)
10190 PRINT "Intensity =";SLINES(I,2): GOTO 10110
10500 CLS:PRINT:PRINT"Examine lines by transition numbers.":PRINT
10510 PRINT "Enter the individual functions numbers as requested. Terminate by entering":PRINT" a <Return> for either. Order of entry is unimportant.":PRINT
16010 IF IPFLAG = 1 THEN PRINT "ON." ELSE PRINT "OFF."
16020 PRINT:PRINT"Do you wish to alter the state of the pause flag? "; : GOSUB 500
16030 IF P$ = "N" THEN RETURN ELSE IF P$ <> "Y" THEN 16020
16040 IF IPFLAG = 0 THEN IPFLAG = 1 ELSE IPFLAG = 0
16050 RETURN
18000 CLS:PRINT:PRINT"Auto-read flag is currently ";
18010 IF IREAD = 0 THEN PRINT "OFF" ELSE PRINT "ON"
18020 PRINT:PRINT"Do you wish to alter its status? ";: GOSUB 500
18030 IF P$ = "N" THEN 63999
18040 IF P$ <> "Y" THEN BEEP: GOTO 18000
18050 IF IREAD = 0 THEN IREAD = 1 ELSE IREAD = 0
18060 GOTO 63999
19000 CLS:PRINT:PRINT"Routine for entering thresholds.":PRINT
19010 PRINT"Rules: Prints all lines between THRESHOLD1 & THRESHOLD2."
19020 PRINT" Set THRESHOLD1 for minimum intensity to print."
19030 PRINT" Set THRESHOLD2 for maximum intensity to print."
19040 PRINT
19050 PRINT" Set both = 0 to print all lines."
19060 PRINT" Set THRESHOLD2 = 0 to print all lines above THRESHOLD1."
19070 PRINT
19080 INPUT"Enter THRESHOLD1: ",THRESHOLD1
19090 INPUT"Enter THRESHOLD2: ",THRESHOLD2
19100 IF THRESHOLD1 > 0 AND THRESHOLD2 = 0 THEN THRESHOLD2 = 1.00001
19110 GOTO 63999
20000 CLS:PRINT:PRINT"Now sorting lines from highest to lowest frequencies (NMR convention).":PRINT
20005 FOR I = 1 TO NL - 1
20006 PRINT ".";
20010 SM = SLINES(I,1): IS = I
20020 FOR J = I + 1 TO NL
20030 IF SLINES(J,1) < SM THEN 20050
20040 IS = J: SM = SLINES(J,1)
20050 NEXT
20060 IF IS = I THEN 20100
20070 FOR K = 0 TO 2: SWAP SLINES(I,K),SLINES(IS,K): NEXT
20100 NEXT
20110 PRINT:PRINT"Sorting completed.": PRINT:PRINT"You now have the option of storing the sorted lines on the disk. Note that":PRINT" this destroys the unsorted lines and reduces the precision!":PRINT
20120 PRINT:PRINT"Put sorted lines on disk? ";: GOSUB 500
20130 IF P$ = "N" THEN 63999
20135 IF P$ <> "Y" THEN 20120
20140 PRINT:PRINT"Are you absolutely sure? ";: GOSUB 500
20142 IF P$ = "N" THEN 63999
20144 IF P$ <> "Y" THEN 20120
20150 PRINT:PRINT"Now replacing unsorted lines with sorted lines!":PRINT
20160 DF$ = FF$ + ".lin": OPEN DF$ FOR OUTPUT AS 2